= form_for @user_session do |f|
  - if @user_session.errors.any?
    #error_explanation
      %h2= "#{pluralize(@user_session.errors.count, "error")} Ошибки входа:"
      %ul
        - @user_session.errors.full_messages.each do |msg|
          %li= msg
  .field
    = f.label :'Имя пользователя'
    = f.text_field :username
  .field
    = f.label :'Пароль'
    = f.text_field :password, :type =>'password'
  .actions
    = f.submit 'Войти'
